<?php

namespace App\Http\Service;

use App\Libs\HttpCurlLibrary;
use Illuminate\Support\Facades\Config;
use Illuminate\Support\Facades\Log;
use App\Models\Platforms;

//帮助函数
class HelpersService extends BaseService
{
   
    public function __construct(Platforms $platforms)
    {
        parent::__construct();
        $this->platforms=$platforms;
    }

    public  function getIp()
    {
        $address=getLocationByIp();

        // dd($address);
        $result=[];
        $result=[
            'ip'=>$address['ip'],
            'region'=>$address['region']
        ];
        return $result;
    }
    

}
